<?php
    include('/../tool/pdo.php');
    include('/../class/public-data.class.php');
    include('/../bll/PublicDataBLL.php');
    include('/../class/token.class.php');
    include('/../bll/TokenBLL.php');
    include('/../class/student-information.class.php');
    include('/../bll/StudentInformationBLL.php');

    $token=isset($_POST['token'])?$_POST['token']:null;
    $department=isset($_POST['department'])?$_POST['department']:'';
    $grade=isset($_POST['grade'])?$_POST['grade']:0;
    $major=isset($_POST['major'])?$_POST['major']:0;
    $class=isset($_POST['class'])?$_POST['class']:0;
    $gender=isset($_POST['gender'])?$_POST['gender']:0;
    $search=isset($_POST['search'])?$_POST['search']:'';
    $page=isset($_POST['page'])?$_POST['page']:0;
    $pageSize=isset($_POST['pageSize'])?$_POST['pageSize']:100;

    $StudentInformationBLL = new StudentInformationBLL();
    $message=$StudentInformationBLL->getStudentList($token,$department,$grade,$major,$class,$gender,$search,$page,$pageSize);
    echo json_encode($message,JSON_UNESCAPED_UNICODE);
?>